function a = one_step_euler_2d(f, M, a_coef, tri, b_edge_value, grad_b_value, b_value,coef)
flux = new_flux_term(f, a_coef, tri, b_edge_value, coef);
f_grad = f_grad_term(f, a_coef,tri, b_value, grad_b_value);
a = zeros(size(a_coef));
N = size(a_coef,1);
for i = 1 : N
    b = zeros(3,1);
    for j = 1 : 3
        b(j) = -sum(flux(i,j,:)) + f_grad(i,j);
        %disp(flux(i,j,:));
    end
    a(i,:) = (2*tri(i).area*M)\b; 
end
end